package com.wqtz.chechai.view.activities;

import android.content.Intent;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.ImageView;
import android.widget.RelativeLayout;
import android.widget.TextView;

import com.wqtz.chechai.R;
import com.wqtz.chechai.base.BaseActivity;
import com.wqtz.chechai.presenter.BasePresent;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;

/**
 * 项目名称： CheChai
 * 创建人 :  Kisum
 * 创建时间: 2017/2/4
 * 合同信息页面
 */
public class LoanContractInfoActivity extends BaseActivity {

    @BindView(R.id.iv_back)
    ImageView mIvBack;
    @BindView(R.id.tv_contract_review)
    TextView mTvontractReview;
    @BindView(R.id.ll_contract_account_unspecific)
    RelativeLayout mLlContractAccountUnspecific;
    @BindView(R.id.ll_client_unspecific)
    RelativeLayout mLlClientUnspecific;
    @BindView(R.id.btn_download_contract)
    Button mBtnDownloadContract;

    @Override
    public void init() {
        ButterKnife.bind(this);
    }

    @Override
    public void loadData() {

    }

    @Override
    public int setContentViews() {
        return R.layout.activity_loan_contract_info;
    }

    @Override
    public BasePresent createPresenter() {
        return null;
    }


    @OnClick({R.id.iv_back, R.id.tv_contract_review, R.id.ll_contract_account_unspecific, R.id.ll_client_unspecific,R.id.btn_download_contract})
    public void onClick(View view) {
        switch (view.getId()) {
            case R.id.iv_back:
                this.finish();
                break;
            //查看合同
            case R.id.tv_contract_review:
                Intent toContractReviewIntent = new Intent(this, ContractReviewActivity.class);
                startActivity(toContractReviewIntent);
                break;
            //指定收款账户
            case R.id.ll_contract_account_unspecific:
                Intent toSpecificAccountIntent = new Intent(this, SpecificAccountActivity.class);
                startActivity(toSpecificAccountIntent);
                break;
            //委托提车人
            case R.id.ll_client_unspecific:
                Intent toSpecificClientIntent = new Intent(this, SpecificClientActivity.class);
                startActivity(toSpecificClientIntent);
                break;
            //下载合同
            case R.id.btn_download_contract:
                Intent toContractReviewIntent2 = new Intent(this, ContractReviewActivity.class);
                startActivity(toContractReviewIntent2);
                //下载
                break;
        }
    }

    @Override
    protected void onResume() {
        super.onResume();
        activitys.add(this); //添加当前的activity
    }
}
